package com.crazyhat.crazyhat.dto;

import java.time.LocalDateTime;

import org.hibernate.validator.constraints.URL;

import com.baomidou.mybatisplus.annotation.TableField;
import com.fasterxml.jackson.annotation.JsonFormat;

import jakarta.validation.constraints.NotEmpty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * 个人消息传输对象
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
public class MessageDTO {
    
    /**
     * 消息ID
     */
    private Integer messageId;

    /**
     * 学号
     */
    private Integer studentId;

    /**
     * 社团ID
     */
    private Integer clubId;

    /**
     * 发送时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime sentTime;

    /**
     * 内容
     */
    @NotEmpty
    private String messageContent;

    /**
     * 社团名称
     */
    @NotEmpty
    private String clubName;

    /**
     * logo地址
     */
    @URL
    private String logoUrl;
}
